<?php$this->breadcrumbs=array(	'Danh sách ­ Done',); ?><h1>Quản lý thông tin Done</h1>
<div class='full-creen'>
	<?php //$listunlock = Dichvudao::listOrder(2);?>
	<?php echo CHtml::link("Export", array('dichvu/exportorder','trangthai'=>2)); ?>
	<div class='m-paging'> 
		<?php $this->widget('MyPage', array('pages' =>  $listunlock['pages'])) ;?>
	</div>
</div>
<div class='full-creen'>
	<div class='right-box-item'>
		<h1>Danh sách ­ Unlock</h1>

	<div class='main-content'>
		<table>
		
			<tr class='header-table'>
				<th width='180px'>IMEI</th>
				<th width='140px'>User</th>
				<th width='200px'>Nhà mạng</th>
				<th width='60px' align='center'>Giá</th>
				<th width='120px'>Ngày order</th>
				<th width='100px'>Trả code</th>
				
			</tr>
		<?php
		foreach ( $listunlock['orders'] as $value){
			echo "<tr class='row-table'>";
			echo "<td '>". $value->noidung. "</td>";
			echo "<td>". $value->tbuser->username." </td>";
			echo "<td>".$value->tbdichvu->tbnhomdichvu->tennhom." - ". $value->tbdichvu->tendichvu. "</td>";
			echo "<td style='text-align:center'>". $value->gia. "</td>";
			echo "<td>". $value->ngaymua. "</td>";
		
			if($value->trangthai ==0){
				echo "<td>Pendding</td>";
			} else if($value->trangthai ==1){
				echo "<td>Done</td>";
			}else if($value->trangthai < 0){
				echo "<td>Refund</td>";
			}
			
			echo "<td>". $value->ketqua. "</td>";
			echo "</tr>";
		}
		?>
		</table>
	</div>
	</div>
</div>